package bizlogic;

import java.util.ArrayList;

import model.HolidayCalendarDTO;
import exception.DAOSystemException;
import dao.DAOFactory;
import dao.HolidayCalendarDAO;


public class HolidayCalendarManager {
	private HolidayCalendarDAO holidayCalendarDAO;
	public HolidayCalendarManager() {
		holidayCalendarDAO = DAOFactory.loadInstance().getHolidayCalendarDAO();
	}
	

	public HolidayCalendarDTO findHolidayCalendar(String id) throws DAOSystemException{
		HolidayCalendarDTO currentHolidayCalendar = new HolidayCalendarDTO();
			currentHolidayCalendar = holidayCalendarDAO.findHolidayCalendar(id);

			return currentHolidayCalendar;

		
	}

	public ArrayList<HolidayCalendarDTO> findAllHolidayCalendar() throws DAOSystemException {
    	ArrayList<HolidayCalendarDTO> currentList = new ArrayList<HolidayCalendarDTO>();

			currentList = holidayCalendarDAO.findAllHolidayCalendars();

			return currentList;
		
    }
	
	
    public void insertHolidayCalendar(HolidayCalendarDTO holidayCalendar) throws DAOSystemException {

    		holidayCalendarDAO.insertHolidayCalendar(holidayCalendar);

    }
    public void updateHolidayCalendar(HolidayCalendarDTO holidayCalendar) throws DAOSystemException {

    		holidayCalendarDAO.updateHolidayCalendar(holidayCalendar);

    }
    public void deleteHolidayCalendar(HolidayCalendarDTO holidayCalendar) throws DAOSystemException {
    		holidayCalendarDAO.deleteHolidayCalendar(holidayCalendar);

    }
}
